﻿#region Using Directives

using System;
using System.Linq;
using System.Text;
using System.ComponentModel;
using System.Collections.Generic;
using System.ComponentModel.Composition;
using Microsoft.VisualStudio.TeamArchitect.PowerTools.Features;

#endregion

namespace FeatureBuilder.ContribLib.ValueProviders
{
    /// <summary>
    /// Sets value based on whether the argument value is null or not
    /// True if not null & false if null
    /// </summary>        
    [DisplayName("IsNotNullProvider")]
    [Description("Validates a value for Is Not Null")]
    [Category("IDE")]
    public class IsNotNullProvider : ValueProvider
    {
        public object Argument { get; set; }

        #region Overrides

        public override object Evaluate()
        {
            return Argument != null;
        }

        #endregion
    }
}
